How does realloc treat null bytes in strings